#include<bits/stdc++.h>
using namespace std;
int n, vis[100005], sum, ans;
int main(){
    ios::sync_with_stdio(0), cin.tie(nullptr), cout.tie(nullptr);
    freopen("duel.in", "r", stdin);
    freopen("duel.out", "w", stdout);
    cin >> n;
    for (int i = 1; i <= n; i ++){
        int r;
        cin >> r;
        vis[r] ++;
    }
    for (int i = 1; i <= 100000; i ++){
        if(!vis[i]) continue;
        sum = max(0, sum - vis[i]);
        sum += vis[i];
    }
    cout << sum;
    return 0;
}
